<?php

if ($_FILES["video"]["error"] == UPLOAD_ERR_OK) {
    echo "ok";
    $tmp_name = $_FILES["video"]["tmp_name"];
    $name = $_FILES["video"]["name"];
    $fileVideo = "/project_".date('Ymdhis')."_".$name;
    $fullUploadDir = Constants::$uploads_dir.$fileVideo;
    echo "<br>tada";
    echo move_uploaded_file($tmp_name, $fullUploadDir);
    echo "<br>tada 2";
}else {
    echo "fail";
    $fileVideo = $_POST['videoHist'];
}

?>
